package com.fy.market.persistent.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 抽奖活动单
 * @author fwq
 * @date 2025-09-29
 * @desc 抽奖活动单
 * @TableName: raffle_activity_order
 * @Package: com.fy.market.persistent.po
 */
@Data
@TableName("raffle_activity_order")
public class RaffleActivityOrder implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 自增ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 用户ID
     */
    @TableField("user_id")
    private Integer userId;

    /**
     * 商品sku
     */
    @TableField("sku")
    private Integer sku;

    /**
     * 活动ID
     */
    @TableField("activity_id")
    private Integer activityId;

    /**
     * 活动名称
     */
    @TableField("activity_name")
    private String activityName;

    /**
     * 抽奖策略ID
     */
    @TableField("strategy_id")
    private Integer strategyId;

    /**
     * 订单ID
     */
    @TableField("order_id")
    private Integer orderId;

    /**
     * 下单时间
     */
    @TableField("order_time")
    private Date orderTime;

    /**
     * 总次数
     */
    @TableField("total_count")
    private Integer totalCount;

    /**
     * 日次数
     */
    @TableField("day_count")
    private Integer dayCount;

    /**
     * 月次数
     */
    @TableField("month_count")
    private Integer monthCount;

    /**
     * 订单状态（1正常 0禁用）
     */
    @TableField("status")
    private Integer status;

    /**
     * 业务仿重ID - 外部透传的，确保幂等
     */
    @TableField("out_business_no")
    private String outBusinessNo;

    /**
     * 创建时间
     */
    @TableField("create_time")
    private Date createTime;

    /**
     * 更新时间
     */
    @TableField("update_time")
    private Date updateTime;
}